package com.neuedu.dao.impl;

import com.neuedu.common.DBUtil;
import com.neuedu.dao.AddDeptmentDao;
import com.neuedu.dao.BaseDao;

import java.sql.Connection;
import java.sql.SQLException;

public class AddDeptmentDaoImpl extends BaseDao implements AddDeptmentDao {

    @Override
    public int addDeptment(Object[] objs) {
        String sql="INSERT INTO deptment(deptnum,deptname,deptclassifyid,depttypeid) VALUES(?,?,?,?)";
        Connection con = DBUtil.getCon();
        int flag=0;
        try {
            flag=this.delUpins(sql,objs,con);
        } catch (SQLException throwables) {
            throwables.printStackTrace();
        }
        return flag;
    }
}
